﻿using Mes.Pendant.Common.DtoMapping;
using Mes.Pendant.Role.Dto;
using StackExchange.Redis;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Volo.Abp.Application.Services;
using Volo.Abp.Domain.Repositories;

namespace Mes.Pendant.Role
{
	public class RoleService : ApplicationService, RoleIService
	{
		private readonly IRepository<RBACFiles.Role, int> _roleRepository;

		public RoleService(IRepository<RBACFiles.Role, int> roleRepository)
		{
			_roleRepository = roleRepository;
		}

		public async Task<List<RoleListDto>> GetRoleList()
		{
			var roleList = await _roleRepository.GetListAsync();
			var roleListDto = roleList.MapToList<RoleListDto>();
			return roleListDto;
		}








	}
}
